home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 1998 November / IRIX 6.5.2 Base Documentation November 1998.img / usr / share / catman / u_man / cat3 / Tk / place.z / place
Text File  |  1998-10-30  |  16KB  |  265 lines

  1.  
  2.  
  3.  
  4. ppppllllaaaacccceeee((((3333TTTTkkkk))))                                                          ppppllllaaaacccceeee((((3333TTTTkkkk))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      place - Geometry manager for fixed or rubber-sheet placement
  10.  
  11. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  12.      ppppllllaaaacccceeee _w_i_n_d_o_w _o_p_t_i_o_n _v_a_l_u_e ?_o_p_t_i_o_n _v_a_l_u_e ...?
  13.  
  14.      ppppllllaaaacccceeee ccccoooonnnnffffiiiigggguuuurrrreeee _w_i_n_d_o_w _o_p_t_i_o_n _v_a_l_u_e ?_o_p_t_i_o_n _v_a_l_u_e ...?
  15.  
  16.      ppppllllaaaacccceeee ffffoooorrrrggggeeeetttt _w_i_n_d_o_w
  17.  
  18.      ppppllllaaaacccceeee iiiinnnnffffoooo _w_i_n_d_o_w
  19.  
  20.      ppppllllaaaacccceeee ssssllllaaaavvvveeeessss _w_i_n_d_o_w
  21.  
  22.  
  23. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  24.      The placer is a geometry manager for Tk.  It provides simple fixed
  25.      placement of windows, where you specify the exact size and location of
  26.      one window, called the _s_l_a_v_e, within another window, called the _m_a_s_t_e_r.
  27.      The placer also provides rubber-sheet placement, where you specify the
  28.      size and location of the slave in terms of the dimensions of the master,
  29.      so that the slave changes size and location in response to changes in the
  30.      size of the master.  Lastly, the placer allows you to mix these styles of
  31.      placement so that, for example, the slave has a fixed width and height
  32.      but is centered inside the master.
  33.  
  34.      If the first argument to the ppppllllaaaacccceeee command is a window path name or
  35.      ccccoooonnnnffffiiiigggguuuurrrreeee then the command arranges for the placer to manage the geometry
  36.      of a slave whose path name is _w_i_n_d_o_w.  The remaining arguments consist of
  37.      one or more _o_p_t_i_o_n-_v_a_l_u_e pairs that specify the way in which _w_i_n_d_o_w's
  38.      geometry is managed.  If the placer is already managing _w_i_n_d_o_w, then the
  39.      _o_p_t_i_o_n-_v_a_l_u_e pairs modify the configuration for _w_i_n_d_o_w.  In this form the
  40.      ppppllllaaaacccceeee command returns an empty string as result.  The following
  41.      _o_p_t_i_o_n-_v_a_l_u_e pairs are supported:
  42.  
  43.      ----iiiinnnn _m_a_s_t_e_r
  44.           _M_a_s_t_e_r specifes the path name of the window relative to which _w_i_n_d_o_w
  45.           is to be placed.  _M_a_s_t_e_r must either be _w_i_n_d_o_w's parent or a
  46.           descendant of _w_i_n_d_o_w's parent.  In addition, _m_a_s_t_e_r and _w_i_n_d_o_w must
  47.           both be descendants of the same top-level window.  These
  48.           restrictions are necessary to guarantee that _w_i_n_d_o_w is visible
  49.           whenever _m_a_s_t_e_r is visible.  If this option isn't specified then the
  50.           master defaults to _w_i_n_d_o_w's parent.
  51.  
  52.      ----xxxx _l_o_c_a_t_i_o_n
  53.           _L_o_c_a_t_i_o_n specifies the x-coordinate within the master window of the
  54.           anchor point for _w_i_n_d_o_w.  The location is specified in screen units
  55.           (i.e. any of the forms accepted by TTTTkkkk____GGGGeeeettttPPPPiiiixxxxeeeellllssss) and need not lie
  56.           within the bounds of the master window.
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. ppppllllaaaacccceeee((((3333TTTTkkkk))))                                                          ppppllllaaaacccceeee((((3333TTTTkkkk))))
  71.  
  72.  
  73.  
  74.      ----rrrreeeellllxxxx _l_o_c_a_t_i_o_n
  75.           _L_o_c_a_t_i_o_n specifies the x-coordinate within the master window of the
  76.           anchor point for _w_i_n_d_o_w.  In this case the location is specified in
  77.           a relative fashion as a floating-point number:  0.0 corresponds to
  78.           the left edge of the master and 1.0 corresponds to the right edge of
  79.           the master.  _L_o_c_a_t_i_o_n need not be in the range 0.0-1.0.  If both ----xxxx |
  80.           and ----rrrreeeellllxxxx are specified for a slave then their values are summed.   |
  81.           For example, ----rrrreeeellllxxxx 0000....5555 ----xxxx ----2222 positions the left edge of the slave 2 |
  82.           pixels to the left of the center of its master.
  83.  
  84.      ----yyyy _l_o_c_a_t_i_o_n
  85.           _L_o_c_a_t_i_o_n specifies the y-coordinate within the master window of the
  86.           anchor point for _w_i_n_d_o_w.  The location is specified in screen units
  87.           (i.e. any of the forms accepted by TTTTkkkk____GGGGeeeettttPPPPiiiixxxxeeeellllssss) and need not lie
  88.           within the bounds of the master window.
  89.  
  90.      ----rrrreeeellllyyyy _l_o_c_a_t_i_o_n
  91.           _L_o_c_a_t_i_o_n specifies the y-coordinate within the master window of the
  92.           anchor point for _w_i_n_d_o_w.  In this case the value is specified in a
  93.           relative fashion as a floating-point number:  0.0 corresponds to the
  94.           top edge of the master and 1.0 corresponds to the bottom edge of the
  95.           master.  _L_o_c_a_t_i_o_n need not be in the range 0.0-1.0.  If both ----yyyy and |
  96.           ----rrrreeeellllyyyy are specified for a slave then their values are summed.  For  |
  97.           example, ----rrrreeeellllyyyy 0000....5555 ----xxxx 3333 positions the top edge of the slave 3 pixels|
  98.           below the center of its master.
  99.  
  100.      ----aaaannnncccchhhhoooorrrr _w_h_e_r_e
  101.           _W_h_e_r_e specifies which point of _w_i_n_d_o_w is to be positioned at the
  102.           (x,y) location selected by the ----xxxx, ----yyyy, ----rrrreeeellllxxxx, and ----rrrreeeellllyyyy options.
  103.           The anchor point is in terms of the outer area of _w_i_n_d_o_w including
  104.           its border, if any.  Thus if _w_h_e_r_e is sssseeee then the lower-right corner
  105.           of _w_i_n_d_o_w's border will appear at the given (x,y) location in the
  106.           master.  The anchor position defaults to nnnnwwww.
  107.  
  108.      ----wwwwiiiiddddtttthhhh _s_i_z_e
  109.           _S_i_z_e specifies the width for _w_i_n_d_o_w in screen units (i.e. any of the
  110.           forms accepted by TTTTkkkk____GGGGeeeettttPPPPiiiixxxxeeeellllssss).  The width will be the outer width
  111.           of _w_i_n_d_o_w including its border, if any.  If _s_i_z_e is an empty string,
  112.           or if no ----wwwwiiiiddddtttthhhh or ----rrrreeeellllwwwwiiiiddddtttthhhh option is specified, then the width
  113.           requested internally by the window will be used.
  114.  
  115.      ----rrrreeeellllwwwwiiiiddddtttthhhh _s_i_z_e
  116.           _S_i_z_e specifies the width for _w_i_n_d_o_w.  In this case the width is
  117.           specified as a floating-point number relative to the width of the
  118.           master: 0.5 means _w_i_n_d_o_w will be half as wide as the master, 1.0
  119.           means _w_i_n_d_o_w will have the same width as the master, and so on.  If |
  120.           both ----wwwwiiiiddddtttthhhh and ----rrrreeeellllwwwwiiiiddddtttthhhh are specified for a slave, their values   |
  121.           are summed.  For example, ----rrrreeeellllwwwwiiiiddddtttthhhh 1111....0000 ----wwwwiiiiddddtttthhhh 5555 makes the slave 5  |
  122.           pixels wider than the master.
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. ppppllllaaaacccceeee((((3333TTTTkkkk))))                                                          ppppllllaaaacccceeee((((3333TTTTkkkk))))
  137.  
  138.  
  139.  
  140.      ----hhhheeeeiiiigggghhhhtttt _s_i_z_e
  141.           _S_i_z_e specifies the height for _w_i_n_d_o_w in screen units (i.e. any of
  142.           the forms accepted by TTTTkkkk____GGGGeeeettttPPPPiiiixxxxeeeellllssss).  The height will be the outer
  143.           dimension of _w_i_n_d_o_w including its border, if any.  If _s_i_z_e is an
  144.           empty string, or if no ----hhhheeeeiiiigggghhhhtttt or ----rrrreeeellllhhhheeeeiiiigggghhhhtttt option is specified,
  145.           then the height requested internally by the window will be used.
  146.  
  147.      ----rrrreeeellllhhhheeeeiiiigggghhhhtttt _s_i_z_e
  148.           _S_i_z_e specifies the height for _w_i_n_d_o_w.  In this case the height is
  149.           specified as a floating-point number relative to the height of the
  150.           master: 0.5 means _w_i_n_d_o_w will be half as high as the master, 1.0
  151.           means _w_i_n_d_o_w will have the same height as the master, and so on.  If|
  152.           both ----hhhheeeeiiiigggghhhhtttt and ----rrrreeeellllhhhheeeeiiiigggghhhhtttt are specified for a slave, their values |
  153.           are summed.  For example, ----rrrreeeellllhhhheeeeiiiigggghhhhtttt 1111....0000 ----hhhheeeeiiiigggghhhhtttt ----2222 makes the slave |
  154.           2 pixels shorter than the master.
  155.  
  156.      ----bbbboooorrrrddddeeeerrrrmmmmooooddddeeee _m_o_d_e
  157.           _M_o_d_e determines the degree to which borders within the master are
  158.           used in determining the placement of the slave.  The default and
  159.           most common value is iiiinnnnssssiiiiddddeeee.  In this case the placer considers the
  160.           area of the master to be the innermost area of the master, inside
  161.           any border:  an option of ----xxxx 0000 corresponds to an x-coordinate just
  162.           inside the border and an option of ----rrrreeeellllwwwwiiiiddddtttthhhh 1111....0000 means _w_i_n_d_o_w will
  163.           fill the area inside the master's border.  If _m_o_d_e is oooouuuuttttssssiiiiddddeeee then
  164.           the placer considers the area of the master to include its border;
  165.           this mode is typically used when placing _w_i_n_d_o_w outside its master,
  166.           as with the options ----xxxx 0000 ----yyyy 0000 ----aaaannnncccchhhhoooorrrr nnnneeee.  Lastly, _m_o_d_e may be
  167.           specified as iiiiggggnnnnoooorrrreeee, in which case borders are ignored:  the area of
  168.           the master is considered to be its official X area, which includes
  169.           any internal border but no external border.  A bordermode of iiiiggggnnnnoooorrrreeee
  170.           is probably not very useful.
  171.  
  172.      If the same value is specified separately with two different options,
  173.      such as ----xxxx and ----rrrreeeellllxxxx, then the most recent option is used and the older
  174.      one is ignored.
  175.  
  176.      The ppppllllaaaacccceeee ssssllllaaaavvvveeeessss command returns a list of all the slave windows for
  177.      which _w_i_n_d_o_w is the master.  If there are no slaves for _w_i_n_d_o_w then an
  178.      empty string is returned.
  179.  
  180.      The ppppllllaaaacccceeee ffffoooorrrrggggeeeetttt command causes the placer to stop managing the geometry
  181.      of _w_i_n_d_o_w.  As a side effect of this command _w_i_n_d_o_w will be unmapped so
  182.      that it doesn't appear on the screen.  If _w_i_n_d_o_w isn't currently managed
  183.      by the placer then the command has no effect.  PPPPllllaaaacccceeee ffffoooorrrrggggeeeetttt returns an
  184.      empty string as result.
  185.  
  186.      The ppppllllaaaacccceeee iiiinnnnffffoooo command returns a list giving the current configuration of
  187.      _w_i_n_d_o_w.  The list consists of _o_p_t_i_o_n-_v_a_l_u_e pairs in exactly the same form
  188.      as might be specified to the ppppllllaaaacccceeee ccccoooonnnnffffiiiigggguuuurrrreeee command.  If the
  189.      configuration of a window has been retrieved with ppppllllaaaacccceeee iiiinnnnffffoooo, that
  190.      configuration can be restored later by first using ppppllllaaaacccceeee ffffoooorrrrggggeeeetttt to erase
  191.      any existing information for the window and then invoking ppppllllaaaacccceeee ccccoooonnnnffffiiiigggguuuurrrreeee
  192.  
  193.  
  194.  
  195.                                                                         PPPPaaaaggggeeee 3333
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. ppppllllaaaacccceeee((((3333TTTTkkkk))))                                                          ppppllllaaaacccceeee((((3333TTTTkkkk))))
  203.  
  204.  
  205.  
  206.      with the saved information.
  207.  
  208.  
  209. FFFFIIIINNNNEEEE PPPPOOOOIIIINNNNTTTTSSSS
  210.      It is not necessary for the master window to be the parent of the slave
  211.      window.  This feature is useful in at least two situations.  First, for
  212.      complex window layouts it means you can create a hierarchy of subwindows
  213.      whose only purpose is to assist in the layout of the parent.  The ``real
  214.      children'' of the parent (i.e. the windows that are significant for the
  215.      application's user interface) can be children of the parent yet be placed
  216.      inside the windows of the geometry-management hierarchy.  This means that
  217.      the path names of the ``real children'' don't reflect the geometry-
  218.      management hierarchy and users can specify options for the real children
  219.      without being aware of the structure of the geometry-management
  220.      hierarchy.
  221.  
  222.      A second reason for having a master different than the slave's parent is
  223.      to tie two siblings together.  For example, the placer can be used to
  224.      force a window always to be positioned centered just below one of its
  225.      siblings by specifying the configuration
  226.  
  227.           ----iiiinnnn _s_i_b_l_i_n_g ----rrrreeeellllxxxx 0000....5555 ----rrrreeeellllyyyy 1111....0000 ----aaaannnncccchhhhoooorrrr nnnn ----bbbboooorrrrddddeeeerrrrmmmmooooddddeeee oooouuuuttttssssiiiiddddeeee
  228.  
  229.      Whenever the sibling is repositioned in the future, the slave will be
  230.      repositioned as well.
  231.  
  232.      Unlike many other geometry managers (such as the packer) the placer does
  233.      not make any attempt to manipulate the geometry of the master windows or
  234.      the parents of slave windows (i.e. it doesn't set their requested sizes).
  235.      To control the sizes of these windows, make them windows like frames and
  236.      canvases that provide configuration options for this purpose.
  237.  
  238.  
  239. KKKKEEEEYYYYWWWWOOOORRRRDDDDSSSS
  240.      geometry manager, height, location, master, place, rubber sheet, slave,
  241.      width
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.                                                                         PPPPaaaaggggeeee 4444
  262.  
  263.  
  264.  
  265.